//
//  TextFiledAddImage.m
//  SHSPZB
//
//  Created by mac on 16/5/12.
//  Copyright © 2016年 Jack. All rights reserved.
//

#import "TextFiledAddImage.h"

#import <UIKit/UIKit.h>


@implementation TextFiledAddImage



+(void)setLeftViewWithTextField:(UITextField *)textField imageName:(NSString *)imageName{
    
    UIImageView *rightView = [[UIImageView alloc]initWithFrame:CGRectMake(0, 0, CGRectGetHeight(textField.frame), CGRectGetHeight(textField.frame))];
    rightView.image = [UIImage imageNamed:imageName];
    //    rightView.size = CGSizeMake(40, 40);
    rightView.contentMode = UIViewContentModeCenter;
    textField.leftView = rightView;
    textField.leftViewMode = UITextFieldViewModeAlways;
    
    
    
    
    
    
}

@end
